package com.cmict.data.framework.common.enums;

import com.cmict.data.framework.common.core.IntArrayValuable;
import lombok.AllArgsConstructor;
import lombok.Getter;

import java.util.Arrays;

/**
 * 通用状态枚举
 *
 * @author awesome
 */
@Getter
@AllArgsConstructor
public enum ConfKeyEnum implements IntArrayValuable {

    SYSTEM_BASE(0, "system_base"),    //系统基本设置
    SYSTEM_SAFE(1, "system_safe"),       // 安全设置
    SYSTEM_ALI_SMS(2, "system_ali_sms"),           //   阿里短信
    SYSTEM_TENCENT_SMS(3, "system_tencent_sms"),      // 腾讯短信
    SYSTEM_EMAIL(4, "system_email");      //  电子邮箱配置

    public static final int[] ARRAYS = Arrays.stream(values()).mapToInt(ConfKeyEnum::getStatus).toArray();


    /**
     * 状态值
     */
    private final Integer status;
    /**
     * 状态名
     */
    private final String confKey;

    @Override
    public int[] array() {
        return ARRAYS;
    }

}
